home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Grab Bag
/
Shareware Grab Bag.iso
/
098
/
eds.arc
/
EDSPB.LSP
< prev
next >
Wrap
Text File
|
1980-01-01
|
600b
|
19 lines
;This function takes two points as input
;and places a point between them. (similar
;to the points function on CADAM)
;
;Function name "EDSPB.LSP" - Execute command "pb"
;
;Written by Steve Brown and Christopher Conrad
;
(defun c:pb ()
(command "osnap" "node")
(setq pt1 (getpoint "\nSelect 1st point: "))
(setq pt2 (getpoint "\nSelect 2nd point: "))
(setq dx (/ (- (car pt2) (car pt1)) 2))
(setq dy (/ (- (cadr pt2) (cadr pt1)) 2))
(setq pt3x (+ (car pt1) dx))
(setq pt3y (+ (cadr pt1) dy))
(command "point" (list pt3x pt3y))
(command "osnap" "off")
)